package ldh.im.base.dao;

import java.util.List;

import ldh.im.base.pojo.CmsCategory;
import ldh.im.base.pojo.where.CmsCategoryWhere;
import org.apache.ibatis.annotations.Param;

/**
* @author: ldh
* @date: 2021-07-04 17:02:35
*/
public interface CmsCategoryDao {

	Integer insert(CmsCategory cmsCategory);

	Integer insertSelective(CmsCategory cmsCategory);

	Integer updateById(CmsCategory cmsCategory);
	
	Integer updateNotNullById(CmsCategory cmsCategory);
	
	Integer deleteById(Long id);

	Integer updateByTenantIdAndName(CmsCategory cmsCategory);
	
	Integer updateNotNullByTenantIdAndName(CmsCategory cmsCategory);
	
	Integer deleteByTenantIdAndName(@Param("tenantId") Long tenantId, @Param("name") String name);

	CmsCategory getById(Long id);

	CmsCategory getByTenantIdAndName(@Param("tenantId") Long tenantId, @Param("name") String name);

	List<CmsCategory> findByCmsCategoryWhere(CmsCategoryWhere cmsCategoryWhere);
	
	Long findTotalByCmsCategoryWhere(CmsCategoryWhere cmsCategoryWhere);
	
	
}
